Not applicable.
Not applicable.
This invention relates to an automated process for filling pharmaceutical prescriptions for medications which may be taken in the form of pills, capsules, caplets, etc., and more particularly, to system and method for visually verifying that the medication with which a container is filled is the correct medication for the prescription being filled.
Within the medical establishment, certain facilities (Veteran""s hospitals, large general hospitals, mail order drug firms, large central drug stores) are required to fill a large number of prescriptions on a routine basis, e.g., daily. To accomplish what is an otherwise manually intensive task, these establishments employ machines. capable of filling these large numbers of prescriptions in a timely manner. The machines not only dispense the requisite number and type of medication into a container, but also attach a label to the container describing both the contents of the container and prescription involved.
Referring to FIGS. 1 and 2, a pill dispensing machine 10 and a schematic of its operation are shown. The particular machine shown in FIG. 1 is manufactured by the assignee of the present application, and sold under the tradename Optifill II(trademark). A machine 10 of the type shown in FIG. 1 includes hundreds of hoppers H located in a dispenser 12 portion of the machine, each hopper being prefilled with a different medication M. These medications are pills which come in a variety of shapes, sizes, and colors. Operation of the machine starts with the generation of a bar coded, patient specific, label L, the information included on the label being taken from a prescription form P such as is issued by a doctor, and this information is read by a reader 14 of the machine. The label is applied to a container C such as a conventional pill bottle, and the information on the label is also supplied to a machine controller 16. Container C is routed along the machine passing a series of filling stations within the dispenser portion of the machine. At the appropriate dispensing station, the hopper H containing the appropriate medication is opened, and the number of pills specified by the prescription are dispensed into the bottle. Once the bottle is filled, a color camera 18 which is located above the path of the bottle captures a near, overhead image of the contents of the bottle. The bottle is then closed with a cap A by a capper 20, and label L is applied to the outside of the bottle by a labeler 22.
As indicated in FIG. 2, and image Ib of the contents of the bottle, as captured by camera 18, is displayed on a video monitor 24, alongside a stored reference image Ir. Image Ir represents one pill, or a prior sample of the type of pills for the medication indicated in prescription P and with which the container should be filled. Monitor 24 is viewed by a pharmacist E. The role of the pharmacist is to verify the contents of the container as indicated by the prescription information printed on label L. If the pharmacist confirms that the bottle is filled with the correct medication, the capped and labeled bottle is made available for delivery to the patient. If the pharmacist rejects the contents of the container, the bottle is automatically removed from the stream of bottles, the prescription information is re-entered into machine 10, and the filling process is repeated.
Other drug or medication dispensing systems are known in the art. For example, U.S. Pat. No. 5,720,154 describes such a system utilizing upper and lower hoppers containing prescription pills which are released by computer control into a container. A somewhat simpler system is described in U.S. Pat. No. 4,573,606. Other systems are described in commonly assigned U.S. Pat. Nos. 5,562,232 and 5,490,610. Control logic for the automated dispensing of pills is described, for example, in U.S. Pat. No. 5,337,919. Other pill dispensing art relates to the timely dispensing of pills to a single patient. See, for example, U.S. Pat. No. 4,640,560.
None of the above referenced patents address the issue of whether or not the correct pill has been dispensed into the correct patient container, and none addresses the use of image processing to automatically perform that task.
Among the several objects of the present invention may be noted the provision of a method and apparatus for filling a pharmaceutical prescription for a medication. In particular, the method and apparatus automatically verify the type of medication dispensed as part of a filling operation performed by the apparatus. The method of the invention performs this verification using an image processing technique.
Another object of the invention is a method and apparatus in which an image of the medication as dispensed into a container is obtained and thereafter image processed to classify attributes of the dispensed medication and to quickly and accurately identify the medication on the basis of the classification. The image of the medication is then compared with the medication requested to be dispensed to fill the prescription and if the identity corresponds with that requested the filled prescription is dispensed to the patient. If, however, the identity does not correspond, or if execution of the method cannot identify the medication, to that requested, the container is set aside for further analysis.
The method of the invention utilizes medication features including the color of pills, their geometry, and surface features to identify the medication used to fill each prescription, and to do so with a high degree of accuracy. This enables the apparatus to quickly and efficiently fill a large number of prescriptions. Because of the accuracy achievable using the image processing techniques of the present invention, an outside agency such as a pharmacist is now needed only to check those filled prescriptions which are rejected or of which the apparatus is unsure, rather than all the prescriptions which are filled. The apparatus is xe2x80x9ctirelessxe2x80x9d and avoids errors which might result from human fatigue. It also is no longer xe2x80x9cbottleneckedxe2x80x9d by the review speed of the pharmacist who previously had to check all prescriptions.
A further object of the invention is an apparatus employing an expandable database containing information about all of the medications dispensed to fill prescriptions, including attributes of each medication. Among the types of attribute information stored in the database are the shape of a pill (e.g., capsule, caplet, cardioid form), the size of the pills, the color or colors of each, and surface features such as indicia on the medication by which the medication is identified by a manufacturer. The image processing method of the invention performs extraction of these various features.
Finally, it is an object of the present invention to substantially reduce the cost of filling a prescription while simultaneously insuring the accuracy of each medication dispensed.
In accordance with the invention, generally stated, apparatus is provided for dispensing a prescribed medication and automatically verifying that the dispensed medication is the prescribed medication. A reader reads a prescription and identifies therefrom which one of a plurality of medications are to be dispensed into a container to fill the prescription. A dispenser dispenses units of the medication from a supply thereof into the container. A camera obtains an image of the units of medication as they reside in the container. An image processor then processes the image to extract features of the medication including the color or colors of the pills, their shape and size, and any surface features (including any markings) they may have. The extracted features are then compared to a database of medication features to identify the dispensed medication based upon the extracted features. A comparison of the extracted and stored features either verifies that the medication in the container is that to be dispensed in accordance with the prescription, or that it is not the medication, or that the system cannot determine if the medication is correct according to the prescription. If there is verification, the container is released for the patient. If there is no verification, the container is set aside and not released to the patient. Other objects and features will be in part apparent and in part pointed out hereinafter.